<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<h1 id="h1_frog">我是一只小青蛙</h1>
<img src="../img/off.gif" alt="" id="off_img">
<script>
    let light = document.getElementById("off_img");
    light.onclick = function (){
        alert("我被点击了");
        light.src= "../img/on.gif";
    }



    let frog = document.getElementById("h1_frog");

    frog.innerHTML=`wo shi nide baba`;


</script>
</body>
</html>